import React, { Component } from 'react'
import RouterView from '../router/RouterView'
import {NavLink} from "react-router-dom"
export class Index extends Component {
    render() {
        let {routes} = this.props
        return (
            <div className="index">
                <header>头部</header>
                <main>
                    <RouterView routes={routes}/>
                </main>
                <footer>
                    <NavLink to="/index/home">首页</NavLink>
                    <NavLink to="/index/classify">分类</NavLink>
                    <NavLink to="/index/shopcar">购物车</NavLink>
                    <NavLink to="/index/my">我的</NavLink>
                </footer>
            </div>
        )
    }
}

export default Index
